home *** CD-ROM | disk | FTP | other *** search
- /*
- ICeTEe.h
-
- Header file for ICeTEe.c
-
- */
-
- #pragma once
-
- #ifndef __H_ICeTEe__
- #define __H_ICeTEe__
-
- #include <TextEdit.h>
- #include <Files.h>
-
- // Component Creator Type
- #define kCreator 'ICTE'
-
- // EXCL - App Creator Types that don't use the patch
- #define rExclusions 128
-
- // ICN# - Icon to use for startup display
- #define rICTEIcon 128
- #define rFailedIcon 129
-
- // STR# - Error messages used for the notification routine
- #define rErrorStrings 128
- #define strMiscErr 1
- #define strNoCMErr 2
- #define strNoICErr 3
- #define strInsufficientICErr 4
- #define strNoMemoryErr 5
- #define strCantFindHelperErr 6
- #define strNoHelperErr 7
- #define strNoURLErr 8
- #define strCantHackIt 9
-
- #define noCMErr -6660
-
- // TEClickUPP - UPP used to create a correct Universal Proc Ptr for the PPC version.
- typedef pascal void (*TEClickProcPtr)(Point pt,Boolean fExtend,TEHandle teh);
-
- enum {
- uppTEClickProcInfo=kPascalStackBased
- | STACK_ROUTINE_PARAMETER(1,SIZE_CODE(sizeof(Point)))
- | STACK_ROUTINE_PARAMETER(2,SIZE_CODE(sizeof(Boolean)))
- | STACK_ROUTINE_PARAMETER(3,SIZE_CODE(sizeof(TEHandle)))
- };
-
- #if USESROUTINEDESCRIPTORS
- typedef UniversalProcPtr TEClickUPP;
-
- #define CallTEClickProc(a,p,e,t) \
- CallUniversalProc((UniversalProcPtr)(a),uppTEClickProcInfo,(p),(e),(t))
- #define NewTEClickProc(a) \
- (TEClickUPP)NewRoutineDescriptor((ProcPtr)(a),uppTEClickProcInfo,GetCurrentISA())
-
- #else
- typedef TEClickProcPtr TEClickUPP;
-
- #define CallTEClickProc(a,p,e,t) (*(a))(p,e,t)
- #define NewTEClickProc(a) (TEClickUPP)(a)
-
- #endif
-
- #define DisposeTEClickProc(a) DisposeRoutineDescriptor((UniversalProcPtr)(a))
-
- // Globals for the patch
- typedef struct icteGlobalsStruct icteGlobals,* icteGlobalsPtr,** icteGlobalsPtrPtr;
- typedef OSType *exPtr,** exHandle;
-
- #if defined(powerc) || defined (__powerc)
- #pragma options align=mac68k
- #endif
- struct icteGlobalsStruct {
- OSType signature; //
- NumVersion version; //
- exHandle exclusions; // Array of OSTypes for apps to exclude
- Handle errors; // STR# resource handle
- TEClickUPP old_teclick; // patched TEClick proc
- };
- #if defined(powerc) || defined(__powerc)
- #pragma options align=reset
- #endif
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- void main(void);
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif /* __H_ICeTEe__ */
-
-
-